
#include <jni.h>
#define CMD_REQ_GPIO 0
#define CMD_SET_GPIO 1
#define CMD_INP_GPIO 2
#define CMD_GET_GPIO 3
#define CMD_RELEASE_GPIO 5
#define CMD_RED_GPIO 6
#define CMD_GREEN_GPIO 7
#define CMD_4G_POWER_ON 8
#define CMD_4G_POWER_OFF 9
#define CMD_RED_GPIO1 10
#define CMD_GREEN_GPIO1 11
#define CMD_HOST_POWER_GPIO 12 
struct UserData{
    int gpio;
    int state;
};


#ifndef _Included_com_example_hellojni
#define _Included_com_example_hellojni
#ifdef __cplusplus
extern "C"
{
#endif

static jint getgpionumber(JNIEnv *env, jobject thiz, jstring gpionumber);
static jint requestGpio(JNIEnv *env, jobject thiz, jint fd, jint num);
static jint releaseGpio(JNIEnv *env, jobject thiz, jint fd, jint num);
static jint openGpioDev(JNIEnv *env, jobject thiz);
static jint closeGpioDev(JNIEnv *env, jobject thiz, jint fd);
static jint setGpioState(JNIEnv *env, jobject thiz, jint fd, jint num,jint state);
static jint getGpioState(JNIEnv *env, jobject thiz, jint fd, jint num);
static jint setGpioInput(JNIEnv *env, jobject thiz, jint fd, jint num) ;
static jint setRedGpio(JNIEnv *env, jobject thiz, jint fd, jint status) ;
static jint setGreenGpio(JNIEnv *env, jobject thiz, jint fd, jint status);
static jint setRedGpioOne(JNIEnv *env, jobject thiz, jint fd, jint status) ;
static jint setGreenGpioOne(JNIEnv *env, jobject thiz, jint fd, jint status);
static jint setHostPowerGpio(JNIEnv *env, jobject thiz, jint fd, jint status);
static jint set4GPower(JNIEnv *env, jobject thiz, jint fd, jint onoff);
static jint setBlLevels(JNIEnv *env, jobject thiz, jintArray levels);
static jint eepromWrite(JNIEnv *env, jobject thiz, jint pos, jbyteArray data);
static jint eepromRead(JNIEnv *env, jobject thiz, jint pos, jint length, jbyteArray data);
static jfloat getCurrentTemperatureValues(JNIEnv *env, jobject thiz);
static jfloat getCurrentHumidityValues(JNIEnv *env, jobject thiz);
static jdouble getCurrentPressureValues(JNIEnv *env, jobject thiz);
	#ifdef __cplusplus
	}
	#endif
#endif
